package edu.hrbu.proxy.dao.impl;

import edu.hrbu.proxy.dao.OrderDao;

/**
 * @author 徐登宇
 */
public class OrderDaoImpl implements OrderDao {

    @Override
    public void generate() {
        try {
//            long begin = System.currentTimeMillis();
            Thread.sleep(123);
//            long end = System.currentTimeMillis();
            System.out.println("==生成订单==");
//            System.out.println("耗时"+(end-begin)+"毫秒");
        } catch (InterruptedException e) {
            e.printStackTrace();
        }
    }

    @Override
    public void modify() {
        try {
//            long begin = System.currentTimeMillis();
            Thread.sleep(321);
//            long end = System.currentTimeMillis();
            System.out.println("==修改订单==");
//            System.out.println("耗时"+(end-begin)+"毫秒");
        } catch (InterruptedException e) {
            e.printStackTrace();
        }
    }
}
